home *** CD-ROM | disk | FTP | other *** search
- #!/bin/sh
- #
- # preflight for Adobe Photoshop CS2 metapackage installer
- #
-
- /bin/echo "Performing preflight for Adobe Photoshop CS2"
-
- # Check OS Version, Minimum is 10.2.8
- OSVERSION=`/usr/bin/sw_vers |/usr/bin/grep ProductVersion |/usr/bin/cut -d: -f2`
- /bin/echo "OSVERSION = ${OSVERSION}"
-
- MAJORVER=`/bin/echo ${OSVERSION} | /usr/bin/cut -d . -f2`
- if [ ${MAJORVER} -lt 3 ] ; then
- # if less then 10.3
- if [ ${MAJORVER} -ne 2 ] ; then
- /bin/echo "Installation of this product is not supported on this version of MacOS. Minimum MacOS requirement is 10.2.8"
- # 96 is the magic base number
- let RETURNCODE=96+16
- exit ${RETURNCODE}
- else
- MINORVER=`/bin/echo ${OSVERSION} | /usr/bin/cut -d. -f3`
- if [ ${MINORVER} -lt 8 ] ; then
- /bin/echo "Installation of this product is not supported on this version of MacOS. Minimum MacOS requirement is 10.2.8"
- let RETURNCODE=96+16
- exit ${RETURNCODE}
- fi
- fi
- fi
-
- # Check Target volume, must be HFS+
- TARGETVOL=$3
- VOLTYPE=`/usr/sbin/diskutil info "${TARGETVOL}" | /usr/bin/grep "Partition Type" | \
- /usr/bin/cut -d: -f2`
- FSTYPE=${VOLTYPE#*Apple_}
- if [ ${FSTYPE} != HFS ] ; then
- echo "Target volume type not supported: ${VOLTYPE}"
- let RETURNCODE=96+17
- exit ${RETURNCODE}
- fi
-
- /bin/echo "Continuing installation."
- exit 0
-
-